home *** CD-ROM | disk | FTP | other *** search
/ ETO Development Tools 4 / ETO Development Tools 4.iso / Essentials / MacApp Documentation / MacApp.TECH$ Archives / 1990 / Oct 90 / MacApp.Tech$ 10⁄5⁄90 / 2110-MPW 3.2 Linker bug-Oct90 < prev    next >
Encoding:
Text File  |  1991-03-06  |  3.4 KB  |  73 lines  |  [TEXT/GEOL]

  1. Item forwarded  by  SANDY        to DIEZMANN     PZZA.SLT
  2.  
  3. Item forwarded  by  DAWSON.M     to SANDY
  4.  
  5. Item    4909590                         3-Oct-90        23:04PDT
  6.  
  7. From:   AUST0338                        AUPtnr - Tactics Int'l,Shillito,IDV
  8.  
  9. To:     MACAPP.TECH$                    MacApp Technical
  10.  
  11. Sub:    MPW 3.2 Linker bug
  12.  
  13. To:         MACAPP.TECH$
  14. From:       AUST0338 - David Shillito
  15. Date:       4th October 1990
  16.  
  17. Subject:    MPW 3.2 linker bug
  18.  
  19. Back on 26th September James Plamondon asked if anyone else had encountered a
  20. bug using the MPW3.2/Pascal 3.1/MacApp2.0 combination. The bug caused crashes
  21. with Bus Error or Illegal Instruction when trying to call a method that resides
  22. in a small segment.
  23.  
  24. Back then I thought he must be imagining it and that he would soon find some
  25. bug in his code that was causing it but the same thing just happened to me.
  26.  
  27. In my case the offending method was the only routine in a segment. The segment
  28. had a size of 60 bytes. When I combined this segment with a few other small
  29. segments the problem went away.
  30.  
  31. The code involved has not been changed for months and the whole program had
  32. been running fine ever since MPW 3.2 came along. Mostly I have been running
  33. without the debugger during this period but I have used the debugger a few
  34. times and the code which broke this time would have been executed then.
  35.  
  36. What I think has changed is this:
  37. 1. My reason for installing MPW 3.2 and its linker was to get more jump table
  38. space because I had exhausted the available space w hen running with the
  39. debugger.
  40. 2. When I installed MPW 3.2 I verified that I could get the additional space by
  41. inspecting the progress messages from the linker and also the link map.
  42. 3. Since I already had around 29K of globals I went on a witch-hunt to see how
  43. much global space I could retrieve so that it would be available for jump table
  44. space. I stopped after a got back a few K, knowing I could retrieve more later
  45. on, if I needed it. I also revised a whole lot of code (for other reasons) and
  46. this resulted in many objects and methods being deleted. However, this meant
  47. that there was no longer any problem with jump table space exceeding 32K (for a
  48. while).
  49. 4. Since that time I have mostly run in non-debug mode. On the couple of
  50. occasions I used debug mode the jump table requirements were probably still
  51. under 32K.
  52. 5. Today I added a large amount of new code with 5 new objects and 20 or 30 new
  53. methods. Today the link progress messages tell me that I need 4096 jump table
  54. entries, ie. 4 over the 32K limit.
  55.  
  56.  
  57. ••• So I think the problem with small segments only occurs when the linker goes
  58. into its new mode of reorganizing jump table space. This will only tend to
  59. occur for large programs compiled with the MacApp debugger. •••
  60.  
  61. By the way, this is a very convincing argument, if ever I needed one, for
  62. staying in MACAPP.TECH$. I only wasted two hours on this because when I traced
  63. everything as far as the small segment I realized that James had described the
  64. same problem only a week ago. If I had not seen that message I would never have
  65. thought that segment size could be the significant aspect of the problem. If I
  66. had to rely on MACDTS... a minimum of several days turnaround under normal
  67. circumstances and right now they are having a break of THREE WEEKS. This one
  68. item of James's has paid for my MACAPP.TECH$ traffic for at least a few months
  69. if not the whole year by saving me time.
  70.  
  71. David Shillito
  72.  
  73.